:: arg 1 Solution Dir
:: arg 2 Solution Name
:: arg 3 Config
:: arg 4 Platform

@echo off
title Batch Build 

:: Environment Settings
set VS_PATH="C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE"
set KEY_WORDS="started: failed warning error"

:: Add to path
set PATH=%VS_PATH%;%PATH%

:: move to the solution directory
pushd %1
	
title Batch Build %3 %4
devenv %2 /Rebuild "%3|%~4" | FindStr /R %KEY_WORDS%
echo.
	
popd
echo.